package com.framework.web.restful.doamin;

import org.apache.commons.collections.map.CaseInsensitiveMap;

import javax.xml.bind.annotation.XmlRootElement;
import java.util.Map;

/**
 * JSON-RPC对应JAVA侧的method映射对象
 * 由于XML转化，必须有ROOT节点且是对象，不能直接用Map接口
 * @author huang.zhong
 * @since 2015-12-08
 *
 */
@XmlRootElement(name="methodMappingBean") 
public class MethodMappingBean {
	public MethodMappingBean() {
		//doNothing;
	}
	/** Method Mapper. */
	private Map<String, APIMethodBean> methodNamesMap;
	
	public Map<String, APIMethodBean> getMethodNamesMap() {
		return methodNamesMap;
	}
	
	public void setMethodNamesMap(Map<String, APIMethodBean> methodNamesMap) {
		this.methodNamesMap = methodNamesMap;
	}
	
	public CaseInsensitiveMap createCaseInsensitiveMap() {
		CaseInsensitiveMap map = new CaseInsensitiveMap(this.methodNamesMap);
		return map;
	}
}
